﻿@model RonYee.Models.File

@{
    ViewBag.Title = "上传文件";
    Layout = "~/Views/Shared/_LayoutOfSecondPage.cshtml";
}

<script src="@Url.Content("~/Scripts/RongeJs/vanadium.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/RongeJs/CheckValue.js")" type="text/javascript"></script>



<div class="box_padding">
    <h3><i class="ui-icons"></i> 上传文件</h3>
    <div class="box_top ui-icons"></div>
    <div class="box_bg">
      <div class="box_padding">
       <div class="border_line">
          @using (Html.BeginForm("Upload", "Files", FormMethod.Post, new { enctype = "multipart/form-data" }))
            {
                //使用此控件会限制文件大小最大上传4M；可在Web.config中配置<httpRuntime executionTimeout="5400"
                // maxRequestLength="2048000" 文件大小  useFullyQualifiedRedirectUrl="false" />
                
                <table width="100%" border="0" cellpadding="0" cellspacing="0">
                  <tbody>
                    <tr>
                        <td class="tdName">选择上传文件</td>
                        <td  class="tdData">
                           <input type="file" name="FileUpload" id="FileUpload" class=":required"  />
                        </td>
                        <td class="tdName">选择文件类别</td>
                        <td class="tdData">
                          @{
                                List<SelectListItem> selectList = new List<SelectListItem>();
                                selectList.Add(new SelectListItem { Text = "--请选择类型--", Value = "0", Selected = true });
                                foreach (object e in Enum.GetValues(typeof(RonYee.Models.Enum.FileType1)))
                                {
                                    selectList.Add(new SelectListItem { Text = Enum.GetName(typeof(RonYee.Models.Enum.FileType1), e), Value = ((int)e).ToString() });
                                }
                                @Html.DropDownList("FileType1", selectList);
                            } 
                        </td>
                    </tr>
                   </tbody>
                 </table>
                <input type="submit" class="Button1 ui-icons" id="Submit" value="上传" title="确认上传" />
            }           
        
       </div>
      </div>
    </div>
    <div class="box_down ui-icons"></div>
</div>
<div class="line_top"></div>

